<!DOCTYPE html>
<html lang="en">
  <head>
    <meta charset="UTF-8" />
    <meta http-equiv="X-UA-Compatible" content="IE=edge" />
    <meta name="viewport" content="width=device-width, initial-scale=1.0" />
    <title>Set 数据结构</title>
  </head>
  <body>
    <script>
      // 1.1、单一个数组
      // let arr = [1, 2, 2, 3, 3, 4];
      // let set1 = new Set(arr);
      // console.log(set1);

      // 1.2、数组去重
      const arr = [1, 99, false, 30, 2, 'abc', 99, 2, 32, 'abc', false];
      let newArr = new Set(arr);
      console.log(Array.from(newArr));
    </script>
  </body>
</html>
